package com.bean;

import lombok.Data;
import lombok.extern.slf4j.Slf4j;
import org.springframework.boot.context.properties.ConfigurationProperties;

/**
 * 这里的变量安装好java就已经有了
 */
@Slf4j
@Data
@ConfigurationProperties(prefix = "java")
public class JavaConfig {
    private String home;
    private String version;

    public void setHome(String home) {
        log.info("---> @ConfigurationProperties 注入 {}",home);
        this.home = home;
    }

    public void setVersion(String version) {
        log.info("---> @ConfigurationProperties 注入 {}",version);
        this.version = version;
    }
}
